<%--
  Created by IntelliJ IDEA.
  User: lzy
  Date: 2018/8/8
  Time: 16:40
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
<span style="color: red; ">
    <%=request.getAttribute("message") == null ? "" : request.getAttribute("message")%>
</span>
<br/>
<%
    String oldName = (String) request.getAttribute("oldName");
    if (oldName == null) {
        oldName = "";
    }
%>
<form action="<%=request.getContextPath()%>/validateCode" method="post">
    <input type="hidden" name="oldname" value=<%=oldName%>>
<table>
    <tr>
        <td>name:</td>
        <td>
            <input type="text" name="name" value=<%=oldName%>>
        </td>
        <td></td>
    </tr>
    <tr>
        <td>checkCode:</td>
        <td>
            <input type="text" name="code">
        </td>
        <td>
            <img src="<%=request.getContextPath()%>/imageServlet" alt="">
        </td>
    </tr>
    <tr>
        <td colspan="3">
            <input type="submit" value="Submit">
        </td>
    </tr>
</table>
</form>
</body>
</html>
